#include<iostream>
using namespace std;

#include<vector>

int numberOfArithmeticSlices(vector<int>& nums) {
	int length1 = nums.size();
	vector<vector<int>>dp1(length1, { 0,0 });
	for (int i = 1; i < length1; i++)
	{
		if (i == 1)
		{
			dp1[i][0] = 0;
			dp1[i][1] = nums[i] - nums[i-1];	
		}
		else
		{
			dp1[i][1] = nums[i] - nums[i - 1];
			if (dp1[i][1] == dp1[i - 1][1])
			{
				dp1[i][0] = dp1[i - 1][0] + 1;
			}
		}
	}
	int number = 0;
	for (int i = 0; i < length1; i++)
	{
		number += dp1[i][0];
	}
	return number;
}

int main()
{
	return 0;
}